import request from '@/utils/request'

// 查询运营上机信息列表
export function listInfo(query) {
  return request({
    url: '/lims/computerinfo/list',
    method: 'get',
    params: query
  })
}
export function listByBatchid(query) {
  return request({
    url: '/lims/computerinfo/listByBatchid',
    method: 'get',
    params: query
  })
}
//查询无Lane号列表
export function listNoLane(query) {
  return request({
    url: '/lims/computerinfo/listNolane',
    method: 'get',
    params: query
  })
}
//查询 Lane号
export function listLaneNum(query) {
  return request({
    url: '/lims/computerinfo/listLaneNum',
    method: 'get',
    params: query
  })
}
//查询有Lane列表
export function listHaveLane(query) {
  return request({
    url: '/lims/computerinfo/listHaveLane',
    method: 'get',
    params: query
  })
}
//查询上机方案无Lane列表
export function listPgNoLane(query) {
  return request({
    url: '/lims/computerinfo/listPgNoLane',
    method: 'get',
    params: query
  })
}
// 查询运营上机信息详细
export function getInfo(computerId) {
  return request({
    url: '/lims/computerinfo/' + computerId,
    method: 'get'
  })
}

// 新增运营上机信息
export function addInfo(data) {
  return request({
    url: '/lims/computerinfo',
    method: 'post',
    data: data
  })
}

// 修改运营上机信息
export function updateInfo(data) {
  return request({
    url: '/lims/computerinfo',
    method: 'put',
    data: data
  })
}
// 批量修改任务下发
export function updateListInfo(data) {
  return request({
    url: '/lims/computerinfo/updateListInfo',
    method: 'put',
    data: data
  })
}
// 删除运营上机信息
export function delInfo(issuedId) {
  return request({
    url: '/lims/computerinfo/' + issuedId,
    method: 'delete'
  })
}
// 周期计算
export function cycleCount(query) {
  return request({
    url: '/lims/computerinfo/cycleCount/',
    method: 'post',
    params: query
  })
}
// 生成包Lane编号
export function createLane(computerId) {
  return request({
    url: '/lims/computerinfo/createLane/'+computerId,
    method: 'get',
  })
}
// 手动新增上机信息
export function toAddNolaneProgram(computerId) {
  return request({
    url: '/lims/computerinfo/toAddNolaneProgram/' + computerId,
    method: 'get'
  })
}
//计算汉明距离
export function computerHm(query) {
  return request({
    url: '/lims/computerinfo/computerHm',
    method: 'get',
    params: query
  })
}
//计算碱基平衡
export function baseEquilibrium(query) {
  return request({
    url: '/lims/computerinfo/baseEquilibrium',
    method: 'get',
    params: query
  })
}
//计算最小碱基平衡
export function baseMinEquilibrium(query) {
  return request({
    url: '/lims/computerinfo/baseMinEquilibrium',
    method: 'get',
    params: query
  })
}


